<?php


namespace app\admin\controller\user;


use app\admin\controller\Controller;
use app\admin\model\user\User as UserModel;
class User extends Controller
{
    /**
     * 用户列表
     * @param string $nickName 昵称
     * @param int $gender 性别
     * @param int $grade 会员等级
     * @return mixed
     * @throws \think\exception\DbException
     */
    public function index($nickName = '', $gender = null)
    {
        $model = new UserModel;
        return $this->fetch('index', [
            'list' => $list = $model->getList($nickName, $gender),
            'names' => $model->getStoreName($list)
        ]);

    }
}